#define _CRT_SECURE_NO_WARNINGS 1

#include<iostream>
using namespace std;
int ans[10000] = { 1,1 };

int main()
{
	int n;
	cin >> n;
	while (n--)
	{
		int w = 0;
		for (int i = 1; i <= ans[0]; i++)
		{
			ans[i] = ans[i] * 2 + w;
			w = ans[i] / 10;
			ans[i] %= 10;
		}
		while (w > 0)
		{
			ans[++ans[0]] += w;
			w /= 10;
		}
	}
	for (int i = ans[0]; i > 0; i--)
		cout << ans[i];
	return 0;
}
